package com.chaofan.messagebook.mapper;


import com.chaofan.messagebook.entity.Admin;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

/**
 * @author 李超凡
 * @since 2022/4/3 18:42
 */
@Mapper
public interface BookMapper {
    @Select("SELECT * FROM admin WHERE account = #{account}")
    Admin selectByAccount(String account);

    @Insert("INSERT INTO admin(account, password) VALUES(#{account}, #{password})")
    int insert(Admin admin);
}
